<?php
	class InitController extends Controller{
		public function init__(){
			parent::init__();
			define('ENCODE','yming455625551');
			$arrData=Dyhb::cookie('user_login');
			if(empty($arrData['user_id'])){
				$GLOBALS['___login___']=false;
				$GLOBALS['IMG_PATH']=str_replace('\\','/',BLOG_PATH.'/data/upload/blogger.gif');
			}else{
				$GLOBALS['___login___']=$arrData;
				$GLOBALS['IMG_PATH']=$arrData['regphoto'];
			}
			$GLOBALS['___config___']=Dyhb::cache("option",'',array('cache_path'=>getcwd().'/data/~runtime/cache_'));
			require_once(BLOG_PATH.'/common/Page.php');
		}

		public function seccode(){
			require_once(BLOG_PATH.'/common/imageCheck.php');
		}
		public function toHtml($code){
			$code=str_replace(" ","&nbsp",$code);
			$code=str_replace("\n","<br>",$code);
			return $code;
		}
	}

?>